package com.cch.cooperation.api.common.config;

import com.cch.cooperation.api.common.properties.UmengProperties;
import com.cch.cooperation.api.common.sdk.umeng.UmengClient;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import javax.annotation.Resource;

@Configuration
public class UmengConfiguration {

    @Resource
    private UmengProperties umengProperties;

    @Bean
    public UmengClient umengClient() {
        return new UmengClient(umengProperties.getUmengAppKey(), umengProperties.getAppKey(), umengProperties.getAppSecret());
    }
}
